/*************************************************************************
	> File Name: B3622.cpp
	> Author: yufangze
	> Mail: 2224590123@qq.com
	> Created Time: 2025-01-10 11:21:41
 ************************************************************************/

#include <iostream>
#include <stack>
#include <cmath>
using namespace std;

int n;

void solve(int x) {
    stack<int> s;
    while (s.size() < n) s.push(x % 2), x /= 2;
    while (!s.empty()) {
        if (s.top() == 0) {
            cout << "N";
        } else {
            cout << "Y";
        }
        s.pop();
    }
    cout << endl;
}

int main() {
    cin >> n;
    for (int i = 0, I = pow(2, n) - 1; i <= I; i++) {
        solve(i);
    }
    return 0;
}
